<?php


namespace app\admin\model;

use think\Model;
class Order extends Model
{
    public function searchKeywordAttr($query, $value)
    {
        if (! empty($value)) {
            $query->where("id","like", "%" . $value . "%");
        }
    }

    public function merchant()
    {
        return $this->hasOne('Merchant', 'merchant_id','merchant_id');
    }
    public function stop()
    {
        return $this->hasOne('stop', 'id','stop_id');
    }
}